package edu.gdkm.tactics;


import edu.gdkm.tactics.behavior.impl.FlyRocketPowered;
import edu.gdkm.tactics.parent.AbstractDuck;

public class MiniDUckSimulator {
    public static void main(String[] args) {

        AbstractDuck abstractDuck = new ModelDuck();
        abstractDuck.display();
        abstractDuck.performFly(); // 原先不会飞

        abstractDuck.setFlyBehavior(new FlyRocketPowered()); // 利用火箭
        abstractDuck.performFly(); // 实现飞行行为
    }
}
